/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package player.model;

import java.util.logging.Level;
import java.util.logging.Logger;

/**
 * Stopirano stanje playera
 * @author Andrej
 */
public class StoppedState implements PlayerState
{
    private PlayerImpl player;

    /**
     * Konstruktor
     * @param player player kojem ovo stanje pripada
     */
    public StoppedState(PlayerImpl player)
    {
        this.player = player;
    }


    public void play()
    {
        try
        { 
            player.setState(new PlayState(player));
            player.initPlayer();
            player.getMediaPlayer().start();
            //player.playbackStarted();
            
        } catch (Exception ex)
        {
            Logger.getLogger(StoppedState.class.getName()).log(Level.SEVERE, null, ex);
        }
        
    }

    public void stop()
    {
        
    }

    public void pause()
    {
        
    }

}
